<include file="Public:top"/>
<div id="main-content" class="clearfix">

    <div id="breadcrumbs">
        <ul class="breadcrumb">
            <li><i class="icon-home"></i> <a href="{:U('Public/main')}">首页</a><span class="divider"><i
                    class="icon-angle-right"></i></span></li>
            <li><a href="__URL__">订单管理</a> <span class="divider"><i class="icon-angle-right"></i></span></li>
            <li class="active">订单列表</li>
        </ul>
    </div>
    <!--#breadcrumbs-->


    <div id="page-content" class="clearfix">

        <div class="page-header position-relative">
            <h1>订单列表<small>订单20分钟后将自动修改为完成状态，订单完成后客人可以获得积分和等级值，在此致歉您可以选择放弃订单。</small>
            </h1>
        </div>
        <!--/page-header-->

        <div class="widget-header widget-header-large">
            <div class="widget-toolbar no-border invoice-info"></div>
            <div class="widget-toolbar hidden-480">
                <a href="__URL__/toExcel/">
                    <i class="icon-print"></i>
                </a>
            </div>
        </div>

        <div class="row-fluid">
            <div class="table-header">
            </div>

            <div id="table_report_wrapper" class="dataTables_wrapper" role="grid">
                <table id="table_report" class="table table-striped table-bordered table-hover dataTable"
                       aria-describedby="table_report_info">
                    <thead>
                    <tr role="row">
                        <th class="" role="columnheader" tabindex="0" aria-controls="table_report" rowspan="1"
                            colspan="1"
                            style="width: 158px;" aria-label="Domain: activate to sort column ascending">订单编号
                        </th>
                        <th class="" role="columnheader" tabindex="0" aria-controls="table_report" rowspan="1"
                            colspan="1"
                            style="width: 124px;" aria-label="Price: activate to sort column ascending">本站会员ID
                        </th>
                        <th class="hidden-480" role="columnheader" tabindex="0" aria-controls="table_report"
                            rowspan="1" colspan="1"
                            style="width: 140px;" aria-label="Clicks: activate to sort column ascending">货物清单(ID/名称/数量/单价)
                        </th>
                        <th class="hidden-480" role="columnheader" tabindex="0" aria-controls="table_report"
                            rowspan="1" colspan="1"
                            style="width: 140px;" aria-label="Clicks: activate to sort column ascending">总金额
                        </th>
                        <th class="hidden-480" role="columnheader" tabindex="0" aria-controls="table_report"
                            rowspan="1" colspan="1"
                            style="width: 140px;" aria-label="Clicks: activate to sort column ascending">获得积分
                        </th>
                        <th class="hidden-480" role="columnheader" tabindex="0" aria-controls="table_report"
                            rowspan="1" colspan="1"
                            style="width: 140px;" aria-label="Clicks: activate to sort column ascending">送货地址
                        </th>
                        <th class="hidden-480" role="columnheader" tabindex="0" aria-controls="table_report"
                            rowspan="1" colspan="1"
                            style="width: 140px;" aria-label="Clicks: activate to sort column ascending">联系人姓名
                        </th>
                        <th class="hidden-phone " role="columnheader" tabindex="0"
                            aria-controls="table_report" rowspan="1"
                            colspan="1" style="width: 177px;" aria-sort="ascending"
                            aria-label=" Update: activate to sort column descending"><i
                                class="icon-time hidden-phone"></i> 下单时间
                        </th>
                        <th class="hidden-phone " role="columnheader" tabindex="0"
                            aria-controls="table_report" rowspan="1"
                            colspan="1" style="width: 177px;" aria-sort="ascending"
                            aria-label=" Update: activate to sort column descending"><i
                                class="icon-time hidden-phone"></i>客户要求送货时间
                        </th>
                        <th class="hidden-480" role="columnheader" tabindex="0" aria-controls="table_report"
                            rowspan="1" colspan="1"
                            style="width: 140px;" aria-label="Clicks: activate to sort column ascending">状态
                        </th>
                        <th class="sorting_disabled" role="columnheader" rowspan="1" colspan="1" style="width: 254px;"
                            aria-label="">操作
                        </th>
                    </tr>
                    </thead>


                    <tbody role="alert" aria-live="polite" aria-relevant="all">
                    <volist name="list" id="vo">
                        <tr class="even">
                            <td class="">{$vo.id}</td>
                            <td class="">{$vo.uid}</td>
                            <td class="hidden-480">
                                <foreach item="shop" name="vo.shop_list">
({$vo.shop_id}/{$shop.name}/{$shop.num}/{$shop.price}￥)<br/>
                                </foreach>
                            </td>
                            <td class="hidden-320">{$vo.total_price}￥</td>
                            <td>{$vo.get_credits}</td>
                            <td class="hidden-480">{$vo.user_address}</td>
                            <td class="hidden-480">{$vo.user_realname}</td>
                            <td class="hidden-480">{$vo.add_time|date="Y-m-d H:i:s",###}</td>
                            <td class="hidden-480">
                                <eq name="vo.delivery_time" value="0">
                                    立即送货
                                    <else/>{$vo.delivery_time|date="Y-m-d H:i:s",###}
                            </eq></td>
                            <td>
                                <eq name="vo.status" value="1"><span class="label label-warning">自动完成</span></eq>
                                <eq name="vo.status" value="0"><span
                                        class="label label-info arrowed arrowed-right">正在处理</span>
                                </eq>
                                <eq name="vo.status" value="2"><span class="label label-inverse arrowed-in">交易失败</span>
                                </eq>
                            </td>
                            <td class="">
                                <div class="hidden-phone visible-desktop btn-group">
                                    <eq name="vo.status" value="0">
                                        <!--<button class="btn btn-mini btn-success"-->
                                                <!--onclick="location = '__URL__/changeStatus/id/{$vo.id}/type/1'"><i-->
                                                <!--class="icon-ok"></i></button>-->
                                        <button class="btn btn-mini btn-danger"
                                                onclick="location = '__URL__/changeStatus/id/{$vo.id}/type/2'" alt="设为失败订单"><i
                                                class="icon-trash"></i>
                                        </button>
                                    </eq>
                                    <!--<button class="btn btn-mini btn-warning"><i class="icon-flag"></i></button>-->
                                </div>
                                <div class="hidden-desktop visible-phone">
                                    <div class="inline position-relative">
                                        <eq name="vo.status" value="0">
                                            <button class="btn btn-minier btn-yellow dropdown-toggle"
                                                    data-toggle="dropdown"><i
                                                    class="icon-caret-down icon-only"></i></button>
                                            <ul class="dropdown-menu dropdown-icon-only dropdown-yellow pull-right dropdown-caret dropdown-close">
                                                <!--<li><a href="__URL__/changeStatus/id/{$vo.id}/type/1" class="tooltip-success"-->
                                                       <!--data-rel="tooltip" title="Edit"-->
                                                       <!--data-placement="left"><span-->
                                                        <!--class="green"><i class="icon-edit"></i></span></a></li>-->
                                                <li><a href="__URL__/changeStatus/id/{$vo.id}/type/2" class="tooltip-error"
                                                       data-rel="tooltip" title="设为失败订单"
                                                       data-placement="left"><span
                                                        class="red"><i class="icon-trash"></i></span> </a></li>
                                            </ul>
                                        </eq>
                                    </div>
                                </div>
                            </td>
                        </tr>
                    </volist>
                    </tbody>
                </table>
                <div class="row-fluid">
                    {$page}
                </div>
            </div>

        </div>
        </div>


        <!--/.fluid-container#main-container-->
        <include file="Public:bottom"/>